1. Field of the Invention
This invention relates to computer systems, and more particularly, to prioritizing requests from multiple agents for access to a resource in a computer system.
2. Description of the Related Art
In digital systems such as computers, portable electronic devices, and so on, multiple agents may issue requests for access to a particular resource. Furthermore, multiple requests for access to the resource may be outstanding at a given time. One example of such a resource is a memory, while examples of agents include processor cores, graphics controllers, I/O interfaces, and so on.
Access to resources such as a memory may be limited in many systems. Accordingly, when multiple requests for access to such a resource are concurrently pending, arbitration algorithms may be implemented to determine which agent receives access at a given time. For example, a memory controller may use an arbitration algorithm to determine which requesting agent is given priority for a next access. In some cases, simple algorithms such as round-robin may be used to choose which requesting agent receives access to the resource. However, in some cases, more complex algorithms for determining priority may be used. In such cases, age of requests, weighting, and other factors may be considered to determine priority. In such cases, the priority for each requesting agent (or for each request) may be given a number that reflects the various prioritization factors. When considering which agent to grant access to the resource, the unit performing the arbitration may compare the number associated with one agent (or request) with a number associated with another agent (or request). Based on the comparison results, the unit performing the arbitration may then grant access to the agent or request having the highest priority.